package com.example.a2306_fx

import android.os.Bundle
import androidx.activity.enableEdgeToEdge
import androidx.appcompat.app.AppCompatActivity
import androidx.core.view.ViewCompat
import androidx.core.view.WindowInsetsCompat
import androidx.navigation.fragment.NavHostFragment
import androidx.navigation.ui.setupWithNavController
import com.blankj.utilcode.util.SPUtils
import com.example.a2306_fx.databinding.ActivityMainBinding
import com.example.base.mvvm.BaseViewActivity

class MainActivity : BaseViewActivity<ActivityMainBinding>() {
    override fun getLayout(): Int  = R.layout.activity_main

    override fun initView() {
        //找到fragment
        val navHostFragment =
            supportFragmentManager.findFragmentById(R.id.fragmentContainerView) as NavHostFragment
        //找到 navController
        val navController = navHostFragment.navController
        //和底部导航绑定
        binding.bottom.setupWithNavController(navController)

        SPUtils.getInstance().put("token","521804d468ff441ba576e79492658ddc")
    }

}